# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=mtx
pkgver=1.3.12
pkgrel=3
pkgdesc="SCSI Media Changer and Backup Device Control"
url="https://sourceforge.net/projects/mtx/"
arch="all"
license="GPL-2.0-only"
subpackages="$pkgname-doc"
source="https://downloads.sourceforge.net/mtx/mtx-$pkgver.tar.gz"
options="!check" # no tests

prepare() {
	default_prepare
	update_config_sub
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--datadir=/usr/share
	make
}

package() {
	make prefix="$pkgdir" mandir="$pkgdir/usr/share/man" install
}

sha512sums="
d54c360608a2c25bd4d31af3e659de0557ed355fbe45d2dbf1341cfc7e468515eb07eb89200b77ee1fe2618139295ba3c3f4340cc43a7c506ced26aab2652028  mtx-1.3.12.tar.gz
"
